/**
 * @author  taiji1985
 * 杩欎釜绫讳负YangMVC妗嗘灦涓殑涓�釜鎺у埗鍣ㄣ�瀹冨垱寤轰簡涓�釜鏁扮粍骞朵互json褰㈠紡杈撳嚭鏁版嵁銆�
 */
package org.demo;

import java.util.ArrayList;

import org.docshare.mvc.Controller;

class A{
	public String tm = "2018-3-3";
	public double money = 12.2;
}
public class LoopController extends Controller {
	public void index(){
		header("Access-Control-Allow-Origin","*");
		ArrayList<A> list = new ArrayList<A>();
		list.add(new A());
		A b = new A();
		b.tm = "2019-3-3";
		b.money =33;
		list.add(b);
		outputJSON(list);
	}
	
	public void form(){
		//header("Access-Control-Allow-Origin","*");
		index();
	}
	public void form2(){
		header("Access-Control-Allow-Origin","*");
		output(param("c"));
	}
}
